import request from '@/utils/request'

// 创建秒杀商品
export function createStoreSeckillManger(data) {
  return request({
    url: '/eb/store-seckill-manger/create',
    method: 'post',
    data: data
  })
}

// 更新秒杀商品
export function updateStoreSeckillManger(data) {
  return request({
    url: '/eb/store-seckill-manger/update',
    method: 'put',
    data: data
  })
}

// 删除秒杀商品
export function deleteStoreSeckillManger(id) {
  return request({
    url: '/eb/store-seckill-manger/delete?id=' + id,
    method: 'delete'
  })
}

// 获得秒杀商品
export function getStoreSeckillManger(id) {
  return request({
    url: '/eb/store-seckill-manger/get?id=' + id,
    method: 'get'
  })
}

// 获得秒杀商品分页
export function getStoreSeckillMangerPage(params) {
  return request({
    url: '/eb/store-seckill-manger/page',
    method: 'get',
    params
  })
}

export function updateStatus(data) {
  return request({
    url: '/eb/store-seckill-manger/update-status',
    method: 'put',
    data: data
  })
}
